// workflows-model.js - A mongoose model
// 
// See http://mongoosejs.com/docs/models.html
// for more of what you can do here.
/**
 * each work contain 1~n operations(works,workflows)
 * usually all operations in work should be done before proceed to next work
 * @param {*} app 
 */
module.exports = function (app) {
  const mongooseClient = app.get('mongooseClient');
  //const { Schema } = mongooseClient;
  const { workflowSchema } = require('./common-schemas');

  return mongooseClient.model('workflows', workflowSchema);
};
